package com.lanxin.xx.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.lanxin.xx.entity.XxInformation;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author zyq
 * @since 2025-07-26
 */
public interface IXxInformationService extends IService<XxInformation> {

    /**
     * 添加信息（包含文件上传）
     */
    boolean addInformation(XxInformation information, MultipartFile file, HttpServletRequest request);

    /**
     * 更新信息（包含文件上传）
     */
    boolean updateInformation(XxInformation information, MultipartFile file, HttpServletRequest request);

    /**
     * 下载
     */
    //void downloadFile(Integer oid, HttpServletResponse response) throws Exception;

    /**
     * 获取最新的指定类型信息
     */
    List<XxInformation> getLatestInformation(Integer typeId, int limit);
}
